﻿using System;
using System.Collections.Generic;
using System.Text;
using yb.commerce.DAL;
using yb.commerce.Model;

namespace yb.commerce.BLL
{
    public class EmailSubscribeBusiness
    {
        public bool Add(EmailSubscribe emailSubscribe) 
        { 
            return new EmailSubscribeDAO().Add(emailSubscribe); 
        }
        public bool Delete(int Id) 
        { 
            return new EmailSubscribeDAO().Delete(Id); 
        }
        public bool Update(EmailSubscribe emailSubscribe) 
        { 
            return new EmailSubscribeDAO().Update(emailSubscribe); 
        }
        public EmailSubscribe GetEntity(int Id) 
        { 
            return new EmailSubscribeDAO().GetEntity(Id); 
        }
        public DataRecordTable GetList(string fieldList, string orderField, bool orderBy, int pageIndex, int pageSize, string where)
        {
            return new EmailSubscribeDAO().GetList(fieldList, orderField, orderBy, pageIndex, pageSize, where);
        }
        public bool IsHaveSameName(EmailSubscribe emailSubscribe) 
        { 
            return new EmailSubscribeDAO().IsHaveSameName(emailSubscribe); 
        }
        public bool DeleteByEmail(EmailSubscribe emailSubscribe) 
        { 
            return new EmailSubscribeDAO().DeleteByEmail(emailSubscribe); 
        }
        public bool UpdateSubscribe(EmailSubscribe emailSubscribe) 
        { 
            return new EmailSubscribeDAO().UpdateSubscribe(emailSubscribe); 
        }
        public EmailSubscribe GetEntityByEmail(EmailSubscribe emailObj) 
        { 
            return new EmailSubscribeDAO().GetEntityByEmail(emailObj); 
        }
    }
}
